﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Young3.FMSearch.Core.Entities.InGame;

namespace Young3.FMSearch.Core.Entities.InGame
{
    public static partial class PositionalRatings
    {
        private static Func<PlayerSkills, decimal> __fsRatings = null;
        public static Func<PlayerSkills, decimal> FastStrikerRatings
        {
            get
            {
                if (__fsRatings == null)
                {
                    __fsRatings = (p) =>
                        (Convert.ToDecimal(
                        p.Crossing*20+
                        p.Dribbling*80+
                        p.Finishing*100+
                        p.FirstTouch*40+
                        p.Heading*40+
                        p.Passing*60+
                        p.Technique*80+

                        p.Anticipation*40+
                        p.Composure*60+
                        p.Concentration*10+
                        p.Creativity*40+
                        p.Decisions*20+
                        p.Influence*10+
                        p.OffTheBall*80+
                        p.Teamwork*10+
                        p.Workrate*20+

                        p.Acceleration*100+
                        p.Agility*40+
                        p.Balance*20+
                        p.Jumping*20+
                        p.Pace*100+
                        p.Stamina*40+
                        p.Strength*20
                        )
                        / Convert.ToDecimal((20+80+100+40+40+60+80+40+60+10+40+20+10+80+10+20+100+
                        40+20+20+100+40+20) * 100));
                }
                return __fsRatings;
            }
        }
    }
}
